from crypt import methods

from flask import Flask, render_template, request, redirect, url_for

app = Flask(__name__)

@app.route('/')
def index():
    return "hello,world"


@app.route('/greet/<name>')
def greet(name):
    return f"Hello, {name}"

@app.route('/int_value/<int:value>')
def int_value(value):
    return f"{value}"

# @app.route("float_value/<float:value>")
# def float_value(value):
#     return f"{value}"

@app.route('/files/<path:filename>')
def serve_file(filename):
    return f'Serving file: {filename}'

@app.route('/submit', methods=['POST'])
def submit():
    return 'Form submitted!'

@app.route('/submit', methods=['GET', 'POST'])
def submit():
    return 'Form submitted!'

@app.route('/submit', methods=['PUT'])
def submit():
    return 'Form submitted!'

@app.route('/submit', methods=['DELETE'])
def submit():
    return 'Form submitted!'

@app.route('/items/<int:item_id>/details')
def item_details(item_id):
    return f'Item details for item ID: {item_id}'


if __name__ == '__main__':
    app.run(debug=True)

